/** kit_admin-v1.0.4 MIT License By http://kit/zhengjinfan.cn */
;/**
 * Name:app.js
 * Author:Van
 * E-mail:zheng_jinfan@126.com
 * Website:http://kit.zhengjinfan.cn/
 * LICENSE:MIT
 */
var tab;
layui.define(['element', 'nprogress', 'form', 'table', 'loader', 'tab', 'navbar', 'onelevel'], function (exports) {
    var $ = layui.jquery,
        element = layui.element,
        layer = layui.layer,
        _win = $(window),
        _doc = $(document),
        _body = $('.kit-body'),
        form = layui.form,
        table = layui.table,
        loader = layui.loader,
        navbar = layui.navbar,
        _componentPath = 'components/';
    tab = layui.tab
    var app = {
        set: function (options) {
            var that = this;
            $.extend(true, that.config, options);
            return that;
        },
        init: function () {
            var that = this,
                _config = that.config;
            tab.set({
                elem: '#container'
            }).render();
            //navbar加载方式一，直接绑定已有的dom元素事件                
            navbar.bind(function (data) {
                tab.tabAdd(data);
            });
            return that;
        }
    };

    //输出test接口
    exports('app', app);
});